/*
	Copyright (C) 2012  Rick Brown

	This program is free software: you can redistribute it and/or modify
	it under the terms of the GNU General Public License as published by
	the Free Software Foundation, either version 3 of the License, or
	(at your option) any later version.

	This program is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	GNU General Public License for more details.

	You should have received a copy of the GNU General Public License
	along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
body
{
	font-family: sans-serif;
}

h1
{
	font-size: 1.6em;
	font-style: italic;
	text-align:center;
	padding-left: 0px;
	padding-right: 0px;
	padding-top: 0px;
	padding-bottom: 10px;
	margin: 0px;
}

h2
{
	font-size: 1.2em;
	text-align: center;
}

div.footer
{
	text-align: center;
	font-style: italic;
	width: 100%;
	border-top: rgb(102, 136, 212) solid 3px;
	margin-top: 1em;
}

div.controls fieldset
{
	width: 30em;
	text-align: center;
	margin-left: auto;
	border-color: rgb(102, 136, 212);
	color: rgb(0, 0, 0);
	opacity: 0.3;
	-webkit-transition: opacity 1s ease-in-out;
	-moz-transition: opacity 1s ease-in-out;
	-ms-transition: opacity 1s ease-in-out;
	-o-transition: opacity 1s ease-in-out;
	transition: opacity 1s ease-in-out;

}

div.controls fieldset:hover
{
	opacity: 1;
}

div.controls label{
	padding-left: 1em;
}

table.stats
{
	text-align: center;
	width: 100%;
}

a
{
	color:#284FA8;
}

a:visited
{
	color: #00CB40;
}

table.stats tbody td
{
	font-weight: bold;
	color: #284FA8;
	background-color: #DAE7FE;
}

table.stats tbody td:last-of-type
{
	color: black;
}

.high
{
	background-color: #A7FC9D !important;
}

.med
{
	background-color: #FFEA20 !important;
}

.low, table.functionCoverage tr.coverFnLo td:last-child
{
	background-color: red !important;
}

table.stats tbody th[scope='row']
{
	text-align: right;
}

table.stats tbody th[scope='row']:after
{
	content: ":";
}

body.nobranch table.stats tbody tr:last-child, body.nofunc table.stats tbody tr:nth-child(2), body.nofunc span.functionNav
{
	/*visibility: hidden; I still want it to take up space so the controls don't jump around */
	display: none;
}

div.header
{
	font-weight: bold;
	display: table;
	width: 100%;
	border-bottom: rgb(102, 136, 212) solid 3px;
	border-top: rgb(102, 136, 212) solid 3px;
	margin-bottom: 1em;
	padding-bottom: .5em;
	padding-top: .5em;
}

div.row
{
	display: table-row;
}

div.header dl.pageView
{
	display: table-cell;
	padding-left: 2em;
	width: 40%;
}

div.header dl.pageView dt
{
	text-align: right;
	width:8em;
	float: left;
	margin-right: 1em;
}

div.header dl dt:after
{
	content: ":";
}

div.header dl dd
{
	color: #284FA8;
	margin-left: 1em;
	white-space: nowrap;
}

body.nolegend .legend
{
	display: none;
}

div.header dl.legend
{
	display: table-row;
}

div.header dl.legend dt, div.header dl.legend dd
{
	font-weight: normal;
	text-align: center;
	color: black;
	display: table-cell;
	float: none;
	width: auto;
}

div.header dl.legend dt
{
	padding-right: .5em;
	padding-left: .5em;
}

div.header dl.legend dd
{
	padding-right: .5em;
	padding-left: .5em;
	border-right-color: white;
	border-right-style: solid;
	border-right-width: .25em;
}

table.index, table.functionCoverage
{
	margin-left:auto;
	margin-right:auto;
	width: 80%;
}

div.descriptions
{
	width:80%;
	margin-left: auto;
	margin-right: auto;
	padding-bottom: 2em;
	background-color: #DAE7FE;
}

div.descriptions dt
{
	font-weight: bold;
	margin-left: 2em;
	margin-top: 1em;
}

div.descriptions dd
{
	margin-left: 4em;
}

table.index td, table.functionCoverage td
{
	background-color: #DAE7FE;
	padding-right: 1em;
	padding-left: 1em;
}

table.index th, table.functionCoverage th, div.descriptions h2
{
	background-color: rgb(102, 136, 212);
	color:white;
}

button.sort{
	border: 0 none;
	background-image: url('');
	background-repeat: no-repeat;
	background-color: transparent;
	width: 16px;
	height: 16px;
	float:right;
}

th[aria-sort="ascending"] button.sort
{
	background-image: url('');
}

th[aria-sort="descending"] button.sort
{
	background-image: url('');
}

table.index thead tr:last-child, table caption, div.controls fieldset legend, .offscreen
{
	/* This moves elements off-screen which are needed for sematic markup but not needed for visual users */
	position: absolute;
	left: -999em;
}

body.nobranch table.index thead th[id^="branch"]
{
	display: none;
}

body.nobranch table.index tbody td[headers^="branch"]
{
	display: none;
}

body.nofunc table.index thead th[id^="function"]
{
	display: none;
}

body.nofunc table.index tbody td[headers^="function"]
{
	display: none;
}

table.index td
{
	text-align: center;
}

table.index td:first-of-type
{
	color:#284FA8;
	text-align:left;
	font-family: monospace;
}

table.coverage
{
	width: 100%;
}

/*
table.coverage tbody tr:nth-child(odd), table.functionCoverage tbody tr:nth-child(odd)
{
	background-color:#e6e6e6;
}
*/

table.coverage td
{
	text-align: center;
}

table.coverage code
{

	white-space: pre;
}

table.coverage td:last-child
{
	text-align: left;
}

table.coverage td:first-child
{
	background-color: #EFE383;
}

table.coverage td:nth-of-type(even), table.coverage th:nth-of-type(even)
{
	border-left: 1px dotted;
	border-right: 1px dotted;
}
/* hmmm, could use colgroups... */
table.coverage td:nth-child(-n+3)
{
	width: 4em;
}

body.nobranch table.coverage td:nth-child(2), body.nobranch table.coverage th:nth-child(2)
{
	display:none;
}

td span.branch
{
	display: inline-block;
	width: 1em;
}

td span.branch:first-of-type
{
	border-left-style: solid;
	border-left-width: 1px;
}

td span.branch:last-of-type
{
	border-right-style: solid;
	border-right-width: 1px;
}



.taken:before
{
	content: "+";
}

.noTaken:before
{
	content: "-";
}

tr.lineCov td:nth-last-child(-n+2), dd.lineCov, .taken
{
	background-color: #CAD7FE;
}

tr.lineNoCov td:nth-last-child(-n+2), dd.lineNoCov, .noTaken
{
	background-color: #FF6230;
}

/* Hide JS controls if script is off or in a shite browser */
body.noscript div.controls, body.noscript button.sort
{
	display: none;
}